Optimal. Leaf size=58 \[ -\frac {\sqrt {a} (A b-a B) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{b^{5/2}}+\frac {x (A b-a B)}{b^2}+\frac {B x^3}{3 b} \]
________________________________________________________________________________________
Rubi [A] time = 0.04, antiderivative size = 58, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.150, Rules used = {459, 321, 205} \begin {gather*} \frac {x (A b-a B)}{b^2}-\frac {\sqrt {a} (A b-a B) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{b^{5/2}}+\frac {B x^3}{3 b} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 205
Rule 321
Rule 459
Rubi steps
\begin {align*} \int \frac {x^2 \left (A+B x^2\right )}{a+b x^2} \, dx &=\frac {B x^3}{3 b}-\frac {(-3 A b+3 a B) \int \frac {x^2}{a+b x^2} \, dx}{3 b}\\ &=\frac {(A b-a B) x}{b^2}+\frac {B x^3}{3 b}-\frac {(a (A b-a B)) \int \frac {1}{a+b x^2} \, dx}{b^2}\\ &=\frac {(A b-a B) x}{b^2}+\frac {B x^3}{3 b}-\frac {\sqrt {a} (A b-a B) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{b^{5/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.04, size = 57, normalized size = 0.98 \begin {gather*} \frac {\sqrt {a} (a B-A b) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{b^{5/2}}+\frac {x (A b-a B)}{b^2}+\frac {B x^3}{3 b} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
IntegrateAlgebraic [F] time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {x^2 \left (A+B x^2\right )}{a+b x^2} \, dx \end {gather*}
Verification is not applicable to the result.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.46, size = 129, normalized size = 2.22 \begin {gather*} \left [\frac {2 \, B b x^{3} - 3 \, {\left (B a - A b\right )} \sqrt {-\frac {a}{b}} \log \left (\frac {b x^{2} - 2 \, b x \sqrt {-\frac {a}{b}} - a}{b x^{2} + a}\right ) - 6 \, {\left (B a - A b\right )} x}{6 \, b^{2}}, \frac {B b x^{3} + 3 \, {\left (B a - A b\right )} \sqrt {\frac {a}{b}} \arctan \left (\frac {b x \sqrt {\frac {a}{b}}}{a}\right ) - 3 \, {\left (B a - A b\right )} x}{3 \, b^{2}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.39, size = 57, normalized size = 0.98 \begin {gather*} \frac {{\left (B a^{2} - A a b\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b} b^{2}} + \frac {B b^{2} x^{3} - 3 \, B a b x + 3 \, A b^{2} x}{3 \, b^{3}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.00, size = 68, normalized size = 1.17 \begin {gather*} \frac {B \,x^{3}}{3 b}-\frac {A a \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b}\, b}+\frac {B \,a^{2} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b}\, b^{2}}+\frac {A x}{b}-\frac {B a x}{b^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 2.23, size = 53, normalized size = 0.91 \begin {gather*} \frac {{\left (B a^{2} - A a b\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b} b^{2}} + \frac {B b x^{3} - 3 \, {\left (B a - A b\right )} x}{3 \, b^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.10, size = 70, normalized size = 1.21 \begin {gather*} x\,\left (\frac {A}{b}-\frac {B\,a}{b^2}\right )+\frac {B\,x^3}{3\,b}+\frac {\sqrt {a}\,\mathrm {atan}\left (\frac {\sqrt {a}\,\sqrt {b}\,x\,\left (A\,b-B\,a\right )}{B\,a^2-A\,a\,b}\right )\,\left (A\,b-B\,a\right )}{b^{5/2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.33, size = 90, normalized size = 1.55 \begin {gather*} \frac {B x^{3}}{3 b} + x \left (\frac {A}{b} - \frac {B a}{b^{2}}\right ) - \frac {\sqrt {- \frac {a}{b^{5}}} \left (- A b + B a\right ) \log {\left (- b^{2} \sqrt {- \frac {a}{b^{5}}} + x \right )}}{2} + \frac {\sqrt {- \frac {a}{b^{5}}} \left (- A b + B a\right ) \log {\left (b^{2} \sqrt {- \frac {a}{b^{5}}} + x \right )}}{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________